Skip to content

refactor: modernize codebase with go fix - #790

Open
buchdag wants to merge 8 commits into
mainfrom
refactor/modernize
Open

refactor: modernize codebase with go fix#790
buchdag wants to merge 8 commits into
mainfrom
refactor/modernize

Conversation

@buchdag

@buchdag buchdag commented Aug 27, 2026

Copy link
Copy Markdown
Member

This PR does a pass of go fix ./... on the codebase.

@buchdag buchdag self-assigned this Aug 27, 2026
@buchdag buchdag added the go Pull requests that update Go code label Aug 27, 2026
@buchdag
buchdag marked this pull request as ready for review August 27, 2026 10:29
@buchdag
buchdag requested a lite review from Copilot August 27, 2026 10:29

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR modernizes the Go codebase by applying automated go fix ./...-style refactors, primarily updating legacy interface{} usage to any and adopting newer standard-library APIs/patterns.

Changes:

  • Replaced many interface{} types with any in template helpers and their tests.
  • Updated several implementations to use modern stdlib helpers/idioms (e.g., strings.Cut, range loops).
  • Refactored generator signal handling goroutine setup (currently introduces a compile error due to an invalid sync.WaitGroup API call).

Reviewed changes

Copilot reviewed 14 out of 14 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
internal/template/yaml.go Switch YAML helper signatures from interface{} to any.
internal/template/yaml_test.go Update test fixtures to use map[string]any / []any.
internal/template/where.go Migrate where helpers to any; simplify label filtering loop.
internal/template/template.go Update getArrayValues signature to any and pointer-kind check.
internal/template/template_test.go Update test struct fields to any; remove redundant loop var rebinding.
internal/template/sort.go Migrate sorting helpers and interfaces to any.
internal/template/sort_test.go Update test function types/expected values to any.
internal/template/reflect.go Migrate deep-get helpers to any.
internal/template/reflect_test.go Update deep-get tests to use any.
internal/template/groupby.go Migrate group-by helpers to any and update string-splitting iteration.
internal/template/functions.go Migrate generic template functions (keys, contains, coalesce, when) to any.
internal/template/functions_test.go Update nil-typed test variable to any.
internal/generator/generator.go Refactor goroutine creation and notify output splitting; currently uses non-existent WaitGroup.Go.
internal/dockerclient/docker_cli.go Simplify image parsing using strings.Cut.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread internal/generator/generator.go
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

go Pull requests that update Go code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants